<!DOCTYPE html>
<html lang="zh" xmlns="http://www.w3.org/1999/xhtml" xmlns:th="https://www.thymeleaf.org"
      xmlns:sec="https://www.thymeleaf.org/thymeleaf-extras-springsecurity5">
<head>
    <title>Spring Security OAuth</title>
    <meta charset="utf-8"/>
    <meta http-equiv="X-UA-Compatible" content="IE=edge"/>
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <link rel="stylesheet" href="/webjars/bootstrap/css/bootstrap.min.css"
          th:href="@{/webjars/bootstrap/css/bootstrap.min.css}"/>
</head>
<body>
<nav class="navbar navbar-expand-sm bg-light">
    <!-- Links -->
    <ul class="navbar-nav">
        <li class="nav-item dropdown">
            <a id="user-menu" href="#" class="dropdown-toggle" data-toggle="dropdown" role="button"
               aria-haspopup="true" aria-expanded="false">
                <span sec:authentication="name">User</span>
            </a>
            <ul class="dropdown-menu">
                <li><a id="sign-out" href="javascript:document.logoutForm.submit()" th:text="#{index.page.menu.sign-out}">Sign Out</a></li>
            </ul>
            <form name="logoutForm" th:action="@{/perform_logout}" method="post" th:hidden="true">
                <input hidden type="submit" value="Sign Out"/>
            </form>
        </li>
    </ul>
</nav>
<div class="container">
    <h1>This is Admin page</h1>
</div>
<script src="/webjars/jquery/3.5.1/jquery.slim.min.js"></script>
<script src="/webjars/bootstrap/4.5.0/js/bootstrap.bundle.min.js"></script>
</body>
</html>